package com.wicket.okrframework.base.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.wicket.okrframework.base.service.MInductionRecordService;
import com.wicket.okrframework.base.service.dto.req.*;
import com.wicket.okrframework.common.dto.FieldInfo;
import com.wicket.okrframework.common.exception.BizException;
import com.wicket.okrframework.common.util.CommonFunctionHelper;
import com.wicket.okrframework.dal.mapper.mbg.InductionRecordMapper;
import com.wicket.okrframework.dal.po.mbg.InductionRecord;
import org.apache.skywalking.apm.toolkit.trace.Tag;
import org.apache.skywalking.apm.toolkit.trace.Tags;
import org.apache.skywalking.apm.toolkit.trace.Trace;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import java.util.ArrayList;
import java.util.List;
import java.util.Map;
import java.util.stream.Collectors;

/**
 * @author ：
 * @since 2022/1/19 15:39
 *
 *
 * @version 1.0
 */
@Service
public class MInductionRecordServiceImpl
        extends ServiceImpl<InductionRecordMapper, InductionRecord>
        implements MInductionRecordService {

    @Autowired
    InductionRecordMapper inductionRecordMapper;

    /**
   * 1-3-13批量查询就职记录列表[601]
   * gen by moon at 10/23/2022, 2:26:06 PM
   */
 @Trace(operationName = "1-3-13批量查询就职记录列表")
 @Tags({@Tag(key = "参数",value = "arg[0]"),
 @Tag(key = "返回值",value = "returnedObj")})
  @Override
  @Transactional(rollbackFor=Exception.class)
  public  List<InductionRecord>  batchQueryInductionRecordList(BatchQueryInductionRecordListReq reqDto) {
     
        try {
            QueryWrapper<InductionRecord> queryWrapper = new QueryWrapper<>();
            reqDto.setIsValid("FALSE");
            if(reqDto.getPerOrgInductionRecordList()==null || reqDto.getPerOrgInductionRecordList().isEmpty()){
                    return new ArrayList<>();
                }
        queryWrapper.in("induction_record_id", reqDto.getPerOrgInductionRecordList());
            Map<String, Object> fieldInfoMap = null;
            fieldInfoMap = CommonFunctionHelper.objectToMapForLamBda(reqDto);
            List<FieldInfo> compareList = CommonFunctionHelper.getRangeField(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperCompare(queryWrapper, compareList, fieldInfoMap);
            List<FieldInfo> likeList = CommonFunctionHelper.getLikeFiled(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperLike(queryWrapper,likeList,fieldInfoMap);
            likeList.addAll(compareList);
            CommonFunctionHelper.buildQueryWrapperEq(queryWrapper, fieldInfoMap,likeList);
            List<FieldInfo> orderList = CommonFunctionHelper.getOrderList(InductionRecord.class);
            //CommonFunctionHelper.buildQueryWrapperOrder(queryWrapper, orderList);
            queryWrapper.orderByAsc("order_number");
queryWrapper.orderByDesc("operate_time");
            return ((List<InductionRecord>) super.list(queryWrapper));
        } catch (Exception e) {
            e.printStackTrace();
            throw new BizException("-1",e,false);
        }
  }

    /**
   * 1-3-13查询就职记录列表[166]
   * gen by moon at 10/23/2022, 2:26:05 PM
   */
 @Trace(operationName = "1-3-13查询就职记录列表")
 @Tags({@Tag(key = "参数",value = "arg[0]"),
 @Tag(key = "返回值",value = "returnedObj")})
  @Override
  @Transactional(rollbackFor=Exception.class)
  public  List<InductionRecord>  queryInductionRecordList(QueryInductionRecordListReq reqDto) {
     
        try {
            QueryWrapper<InductionRecord> queryWrapper = new QueryWrapper<>();
            reqDto.setIsValid("FALSE");
            
            Map<String, Object> fieldInfoMap = null;
            fieldInfoMap = CommonFunctionHelper.objectToMapForLamBda(reqDto);
            List<FieldInfo> compareList = CommonFunctionHelper.getRangeField(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperCompare(queryWrapper, compareList, fieldInfoMap);
            List<FieldInfo> likeList = CommonFunctionHelper.getLikeFiled(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperLike(queryWrapper,likeList,fieldInfoMap);
            likeList.addAll(compareList);
            CommonFunctionHelper.buildQueryWrapperEq(queryWrapper, fieldInfoMap,likeList);
            List<FieldInfo> orderList = CommonFunctionHelper.getOrderList(InductionRecord.class);
            //CommonFunctionHelper.buildQueryWrapperOrder(queryWrapper, orderList);
            queryWrapper.orderByAsc("order_number");
queryWrapper.orderByDesc("operate_time");
            return ((List<InductionRecord>) super.list(queryWrapper));
        } catch (Exception e) {
            e.printStackTrace();
            throw new BizException("-1",e,false);
        }
  }

    /**
   * 1-3-13查询就职记录详情[165]
   * gen by moon at 3/31/2023, 3:24:03 AM
   */
 @Trace(operationName = "1-3-13查询就职记录详情")
 @Tags({@Tag(key = "参数",value = "arg[0]"),
 @Tag(key = "返回值",value = "returnedObj")})
  @Override
  @Transactional(rollbackFor=Exception.class)
  public  InductionRecord  queryinductionRecordDetail(QueryinductionRecordDetailReq reqDto) {
     
        try {
         reqDto.setIsValid("FALSE");
            QueryWrapper<InductionRecord> queryWrapper = new QueryWrapper<>();
            Map<String, Object> fieldInfoMap = null;
            fieldInfoMap = CommonFunctionHelper.objectToMapForLamBda(reqDto);
            CommonFunctionHelper.buildQueryWrapperEq(queryWrapper, fieldInfoMap, new ArrayList<>());
            queryWrapper.orderByDesc("create_time");
            List<InductionRecord> retList = super.list(queryWrapper);
            if(retList!=null && retList.size()>0){
                InductionRecord retData = retList.get(0);
                
                return retData;
            }
            return null;
      } catch (Exception e) {
          e.printStackTrace();
          throw new BizException("-1",e,false);
      }
  }

    /**
   * 1-3-13新增就职记录[162]
   * gen by moon at 10/23/2022, 2:26:02 PM
   */
 @Trace(operationName = "1-3-13新增就职记录")
 @Tags({@Tag(key = "参数",value = "arg[0]"),
 @Tag(key = "返回值",value = "returnedObj")})
  @Override
  @Transactional(rollbackFor=Exception.class)
  public  String  addInductionRecord(InductionRecord inductionRecord) {
     inductionRecord.setInductionRecordId(CommonFunctionHelper.getUid());//DISTRIBUTED_ID
inductionRecord.setIsTransaction("FALSE");
inductionRecord.setInductionEndTime(CommonFunctionHelper.getFutureTime());//FUTURE_CURRENT_TIME
inductionRecord.setBatchEndTime(CommonFunctionHelper.getFutureTime());//FUTURE_CURRENT_TIME
inductionRecord.setIsArchive("FALSE");
inductionRecord.setArchivngType("NOT_ARCHIVE");
inductionRecord.setOperationInductionId(CommonFunctionHelper.getBaseInfoFromLocal().getSpecInductionRecordId());//CURRENT_INDUCTIONID
inductionRecord.setCreateInductionId(CommonFunctionHelper.getBaseInfoFromLocal().getSpecInductionRecordId());//CURRENT_INDUCTIONID
if(inductionRecord!=null && inductionRecord.getSubjectLifeCycle()!=null &&  inductionRecord.getSubjectLifeCycle().equals("CURRENTLY_VALID")) {
            inductionRecord.setReleaseInductionId(CommonFunctionHelper.getBaseInfoFromLocal().getSpecInductionRecordId());//RELEASED_CURRENT_INDUCTIONID
          }
inductionRecord.setOperateTime(CommonFunctionHelper.getCurrentTime());//SYSTEM_CURRENT_TIME
inductionRecord.setCreateTime(CommonFunctionHelper.getCurrentTime());//SYSTEM_CURRENT_TIME
if(inductionRecord!=null && inductionRecord.getSubjectLifeCycle()!=null && inductionRecord.getSubjectLifeCycle().equals("CURRENTLY_VALID")){
             inductionRecord.setReleaseTime(CommonFunctionHelper.getCurrentTime());//RELEASE_SYSTEM_CURRENT_TIME
            }
inductionRecord.setIsValid("FALSE");
     if(super.save(inductionRecord)){
        return inductionRecord.getInductionRecordId();
     }else {
        return "-1";
     }
    
  }

    /**
   * 1-3-13批量修改就职记录[1647]
   * gen by moon at 10/23/2022, 2:26:09 PM
   */
 @Trace(operationName = "1-3-13批量修改就职记录")
 @Tags({@Tag(key = "参数",value = "arg[0]"),
 @Tag(key = "返回值",value = "returnedObj")})
  @Override
  @Transactional(rollbackFor=Exception.class)
  public  boolean  batchUpdateInductionRecord(List<InductionRecord> inductionRecord) {
     
      if(inductionRecord==null || inductionRecord.size()==0){
        return false;
      }
        return super.saveOrUpdateBatch(inductionRecord);
      
  }

    /**
   * 1-3-13批量查询就职记录列表By身份ID[1598]
   * gen by moon at 10/23/2022, 2:26:08 PM
   */
 @Trace(operationName = "1-3-13批量查询就职记录列表By身份ID")
 @Tags({@Tag(key = "参数",value = "arg[0]"),
 @Tag(key = "返回值",value = "returnedObj")})
  @Override
  @Transactional(rollbackFor=Exception.class)
  public  List<InductionRecord>  batchQueryInductionRecordListByIds(BatchQueryInductionRecordListByIdsReq reqDto) {
     
        try {
            QueryWrapper<InductionRecord> queryWrapper = new QueryWrapper<>();
            reqDto.setIsValid("FALSE");
            if(reqDto.getOrgStaffList()==null || reqDto.getOrgStaffList().isEmpty()){
                    return new ArrayList<>();
                }
        queryWrapper.in("original_role_member_id", reqDto.getOrgStaffList());
            Map<String, Object> fieldInfoMap = null;
            fieldInfoMap = CommonFunctionHelper.objectToMapForLamBda(reqDto);
            List<FieldInfo> compareList = CommonFunctionHelper.getRangeField(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperCompare(queryWrapper, compareList, fieldInfoMap);
            List<FieldInfo> likeList = CommonFunctionHelper.getLikeFiled(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperLike(queryWrapper,likeList,fieldInfoMap);
            likeList.addAll(compareList);
            CommonFunctionHelper.buildQueryWrapperEq(queryWrapper, fieldInfoMap,likeList);
            List<FieldInfo> orderList = CommonFunctionHelper.getOrderList(InductionRecord.class);
            //CommonFunctionHelper.buildQueryWrapperOrder(queryWrapper, orderList);
            queryWrapper.orderByAsc("order_number");
queryWrapper.orderByDesc("operate_time");
            return ((List<InductionRecord>) super.list(queryWrapper));
        } catch (Exception e) {
            e.printStackTrace();
            throw new BizException("-1",e,false);
        }
  }

    /**
   * 1-3-13批量增就职记录[2271]
   * gen by moon at 10/23/2022, 2:26:15 PM
   */
 @Trace(operationName = "1-3-13批量增就职记录")
 @Tags({@Tag(key = "参数",value = "arg[0]"),
 @Tag(key = "返回值",value = "returnedObj")})
  @Override
  @Transactional(rollbackFor=Exception.class)
  public  boolean  batchAddInductionRecord(List<InductionRecord> inductionRecord) {
     
      if(inductionRecord==null || inductionRecord.size()==0){
        return false;
      }
      
      return super.saveBatch(inductionRecord.stream().map(item->{
       item.setInductionRecordId(CommonFunctionHelper.getUid());//DISTRIBUTED_ID
          return item;
      }).collect(Collectors.toList()));
  }

    /**
   * 1-3-13批量查就职记录By角色编码[1745]
   * gen by moon at 10/23/2022, 2:26:14 PM
   */
 @Trace(operationName = "1-3-13批量查就职记录By角色编码")
 @Tags({@Tag(key = "参数",value = "arg[0]"),
 @Tag(key = "返回值",value = "returnedObj")})
  @Override
  @Transactional(rollbackFor=Exception.class)
  public  List<InductionRecord>  batchQueryInductionRecordByRoleCode(BatchQueryInductionRecordByRoleCodeReq reqDto) {
     
        try {
            QueryWrapper<InductionRecord> queryWrapper = new QueryWrapper<>();
            reqDto.setIsValid("FALSE");
            if(reqDto.getOrgInductionRecordList()==null || reqDto.getOrgInductionRecordList().isEmpty()){
                    return new ArrayList<>();
                }
        queryWrapper.in("position_role_code", reqDto.getOrgInductionRecordList());
            Map<String, Object> fieldInfoMap = null;
            fieldInfoMap = CommonFunctionHelper.objectToMapForLamBda(reqDto);
            List<FieldInfo> compareList = CommonFunctionHelper.getRangeField(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperCompare(queryWrapper, compareList, fieldInfoMap);
            List<FieldInfo> likeList = CommonFunctionHelper.getLikeFiled(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperLike(queryWrapper,likeList,fieldInfoMap);
            likeList.addAll(compareList);
            CommonFunctionHelper.buildQueryWrapperEq(queryWrapper, fieldInfoMap,likeList);
            List<FieldInfo> orderList = CommonFunctionHelper.getOrderList(InductionRecord.class);
            //CommonFunctionHelper.buildQueryWrapperOrder(queryWrapper, orderList);
            
            return ((List<InductionRecord>) super.list(queryWrapper));
        } catch (Exception e) {
            e.printStackTrace();
            throw new BizException("-1",e,false);
        }
  }

    /**
   * 1-3-13批量查就职记录By部门职务ID[1744]
   * gen by moon at 10/23/2022, 2:26:13 PM
   */
 @Trace(operationName = "1-3-13批量查就职记录By部门职务ID")
 @Tags({@Tag(key = "参数",value = "arg[0]"),
 @Tag(key = "返回值",value = "returnedObj")})
  @Override
  @Transactional(rollbackFor=Exception.class)
  public  List<InductionRecord>  batchQueryInductionRecordByDeptPositionId(BatchQueryInductionRecordByDeptPositionIdReq reqDto) {
     
        try {
            QueryWrapper<InductionRecord> queryWrapper = new QueryWrapper<>();
            reqDto.setIsValid("FALSE");
            if(reqDto.getOrgInductionRecordList()==null || reqDto.getOrgInductionRecordList().isEmpty()){
                    return new ArrayList<>();
                }
        queryWrapper.in("dept_position_relationship_id", reqDto.getOrgInductionRecordList());
            Map<String, Object> fieldInfoMap = null;
            fieldInfoMap = CommonFunctionHelper.objectToMapForLamBda(reqDto);
            List<FieldInfo> compareList = CommonFunctionHelper.getRangeField(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperCompare(queryWrapper, compareList, fieldInfoMap);
            List<FieldInfo> likeList = CommonFunctionHelper.getLikeFiled(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperLike(queryWrapper,likeList,fieldInfoMap);
            likeList.addAll(compareList);
            CommonFunctionHelper.buildQueryWrapperEq(queryWrapper, fieldInfoMap,likeList);
            List<FieldInfo> orderList = CommonFunctionHelper.getOrderList(InductionRecord.class);
            //CommonFunctionHelper.buildQueryWrapperOrder(queryWrapper, orderList);
            
            return ((List<InductionRecord>) super.list(queryWrapper));
        } catch (Exception e) {
            e.printStackTrace();
            throw new BizException("-1",e,false);
        }
  }

    /**
   * 1-3-13批量查就职记录By职务ID[1743]
   * gen by moon at 10/23/2022, 2:26:13 PM
   */
 @Trace(operationName = "1-3-13批量查就职记录By职务ID")
 @Tags({@Tag(key = "参数",value = "arg[0]"),
 @Tag(key = "返回值",value = "returnedObj")})
  @Override
  @Transactional(rollbackFor=Exception.class)
  public  List<InductionRecord>  batchQueryInductionRecordByPositionId(BatchQueryInductionRecordByPositionIdReq reqDto) {
     
        try {
            QueryWrapper<InductionRecord> queryWrapper = new QueryWrapper<>();
            reqDto.setIsValid("FALSE");
            if(reqDto.getOrgInductionRecordList()==null || reqDto.getOrgInductionRecordList().isEmpty()){
                    return new ArrayList<>();
                }
        queryWrapper.in("position_id", reqDto.getOrgInductionRecordList());
            Map<String, Object> fieldInfoMap = null;
            fieldInfoMap = CommonFunctionHelper.objectToMapForLamBda(reqDto);
            List<FieldInfo> compareList = CommonFunctionHelper.getRangeField(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperCompare(queryWrapper, compareList, fieldInfoMap);
            List<FieldInfo> likeList = CommonFunctionHelper.getLikeFiled(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperLike(queryWrapper,likeList,fieldInfoMap);
            likeList.addAll(compareList);
            CommonFunctionHelper.buildQueryWrapperEq(queryWrapper, fieldInfoMap,likeList);
            List<FieldInfo> orderList = CommonFunctionHelper.getOrderList(InductionRecord.class);
            //CommonFunctionHelper.buildQueryWrapperOrder(queryWrapper, orderList);
            
            return ((List<InductionRecord>) super.list(queryWrapper));
        } catch (Exception e) {
            e.printStackTrace();
            throw new BizException("-1",e,false);
        }
  }

    /**
   * 1-3-13批量查询就职记录By编制ID[1731]
   * gen by moon at 10/23/2022, 2:26:12 PM
   */
 @Trace(operationName = "1-3-13批量查询就职记录By编制ID")
 @Tags({@Tag(key = "参数",value = "arg[0]"),
 @Tag(key = "返回值",value = "returnedObj")})
  @Override
  @Transactional(rollbackFor=Exception.class)
  public  List<InductionRecord>  batchQueryInductionRecordByStaffingID(BatchQueryInductionRecordByStaffingIDReq reqDto) {
     
        try {
            QueryWrapper<InductionRecord> queryWrapper = new QueryWrapper<>();
            reqDto.setIsValid("FALSE");
            if(reqDto.getOrgInductionRecordList()==null || reqDto.getOrgInductionRecordList().isEmpty()){
                    return new ArrayList<>();
                }
        queryWrapper.in("staffing_id", reqDto.getOrgInductionRecordList());
            Map<String, Object> fieldInfoMap = null;
            fieldInfoMap = CommonFunctionHelper.objectToMapForLamBda(reqDto);
            List<FieldInfo> compareList = CommonFunctionHelper.getRangeField(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperCompare(queryWrapper, compareList, fieldInfoMap);
            List<FieldInfo> likeList = CommonFunctionHelper.getLikeFiled(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperLike(queryWrapper,likeList,fieldInfoMap);
            likeList.addAll(compareList);
            CommonFunctionHelper.buildQueryWrapperEq(queryWrapper, fieldInfoMap,likeList);
            List<FieldInfo> orderList = CommonFunctionHelper.getOrderList(InductionRecord.class);
            //CommonFunctionHelper.buildQueryWrapperOrder(queryWrapper, orderList);
            
            return ((List<InductionRecord>) super.list(queryWrapper));
        } catch (Exception e) {
            e.printStackTrace();
            throw new BizException("-1",e,false);
        }
  }

    /**
   * 1-3-13批量删除就职记录[1685]
   * gen by moon at 10/23/2022, 2:26:10 PM
   */
 @Trace(operationName = "1-3-13批量删除就职记录")
 @Tags({@Tag(key = "参数",value = "arg[0]"),
 @Tag(key = "返回值",value = "returnedObj")})
  @Override
  @Transactional(rollbackFor=Exception.class)
  public  boolean  batchDeleteInductionRecord(List<String> reqDto) {
     
          if(reqDto==null || reqDto.size()==0){
            return false;
          }
          
          return super.removeByIds(reqDto);
  }

    /**
   * 1-3-13批量查询员工就职记录列表（边界）[1586]
   * gen by moon at 10/23/2022, 2:26:08 PM
   */
 @Trace(operationName = "1-3-13批量查询员工就职记录列表（边界）")
 @Tags({@Tag(key = "参数",value = "arg[0]"),
 @Tag(key = "返回值",value = "returnedObj")})
  @Override
  @Transactional(rollbackFor=Exception.class)
  public  List<InductionRecord>  batchQueryStaffInductionRecord(BatchQueryStaffInductionRecordReq reqDto) {
     
        try {
            QueryWrapper<InductionRecord> queryWrapper = new QueryWrapper<>();
            
            if(reqDto.getOrgInductionRecordList()==null || reqDto.getOrgInductionRecordList().isEmpty()){
                    return new ArrayList<>();
                }
        queryWrapper.in("original_role_member_id", reqDto.getOrgInductionRecordList());
            Map<String, Object> fieldInfoMap = null;
            fieldInfoMap = CommonFunctionHelper.objectToMapForLamBda(reqDto);
            List<FieldInfo> compareList = CommonFunctionHelper.getRangeField(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperCompare(queryWrapper, compareList, fieldInfoMap);
            List<FieldInfo> likeList = CommonFunctionHelper.getLikeFiled(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperLike(queryWrapper,likeList,fieldInfoMap);
            likeList.addAll(compareList);
            CommonFunctionHelper.buildQueryWrapperEq(queryWrapper, fieldInfoMap,likeList);
            List<FieldInfo> orderList = CommonFunctionHelper.getOrderList(InductionRecord.class);
            //CommonFunctionHelper.buildQueryWrapperOrder(queryWrapper, orderList);
            
            return ((List<InductionRecord>) super.list(queryWrapper));
        } catch (Exception e) {
            e.printStackTrace();
            throw new BizException("-1",e,false);
        }
  }

    /**
   * 1-3-13批量查非直属就职记录[1477]
   * gen by moon at 10/23/2022, 2:26:07 PM
   */
 @Trace(operationName = "1-3-13批量查非直属就职记录")
 @Tags({@Tag(key = "参数",value = "arg[0]"),
 @Tag(key = "返回值",value = "returnedObj")})
  @Override
  @Transactional(rollbackFor=Exception.class)
  public  List<InductionRecord>  batchQueryUndoDirectInductionRecord(BatchQueryUndoDirectInductionRecordReq reqDto) {
     
        try {
            QueryWrapper<InductionRecord> queryWrapper = new QueryWrapper<>();
            
            if(reqDto.getOrgInductionRecordList()==null || reqDto.getOrgInductionRecordList().isEmpty()){
                    return new ArrayList<>();
                }
        queryWrapper.in("entity_id", reqDto.getOrgInductionRecordList());
            Map<String, Object> fieldInfoMap = null;
            fieldInfoMap = CommonFunctionHelper.objectToMapForLamBda(reqDto);
            List<FieldInfo> compareList = CommonFunctionHelper.getRangeField(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperCompare(queryWrapper, compareList, fieldInfoMap);
            List<FieldInfo> likeList = CommonFunctionHelper.getLikeFiled(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperLike(queryWrapper,likeList,fieldInfoMap);
            likeList.addAll(compareList);
            CommonFunctionHelper.buildQueryWrapperEq(queryWrapper, fieldInfoMap,likeList);
            List<FieldInfo> orderList = CommonFunctionHelper.getOrderList(InductionRecord.class);
            //CommonFunctionHelper.buildQueryWrapperOrder(queryWrapper, orderList);
            queryWrapper.orderByAsc("first_letter");
queryWrapper.orderByDesc("operate_time");
            return ((List<InductionRecord>) super.list(queryWrapper));
        } catch (Exception e) {
            e.printStackTrace();
            throw new BizException("-1",e,false);
        }
  }

    /**
   * 1-3-13删除就职记录[164]
   * gen by moon at 10/23/2022, 2:26:04 PM
   */
 @Trace(operationName = "1-3-13删除就职记录")
 @Tags({@Tag(key = "参数",value = "arg[0]"),
 @Tag(key = "返回值",value = "returnedObj")})
  @Override
  @Transactional(rollbackFor=Exception.class)
  public  boolean  deleteInductionRecord(String inductionRecordId ) {
     
      return super.removeById(inductionRecordId);
  }

    /**
   * 1-3-13修改就职记录[163]
   * gen by moon at 10/23/2022, 2:26:03 PM
   */
 @Trace(operationName = "1-3-13修改就职记录")
 @Tags({@Tag(key = "参数",value = "arg[0]"),
 @Tag(key = "返回值",value = "returnedObj")})
  @Override
  @Transactional(rollbackFor=Exception.class)
  public  boolean  updateInductionRecord(InductionRecord inductionRecord) {
     
        return super.updateById(inductionRecord);
  }

    /**
   * 1-3-13批量查询就职记录列表ByUserId[1703]
   * gen by moon at 10/23/2022, 2:26:11 PM
   */
 @Trace(operationName = "1-3-13批量查询就职记录列表ByUserId")
 @Tags({@Tag(key = "参数",value = "arg[0]"),
 @Tag(key = "返回值",value = "returnedObj")})
  @Override
  @Transactional(rollbackFor=Exception.class)
  public  List<InductionRecord>  batchQueryInductionRecordListByUserId(BatchQueryInductionRecordListByUserIdReq reqDto) {
     
        try {
            QueryWrapper<InductionRecord> queryWrapper = new QueryWrapper<>();
            reqDto.setIsValid("FALSE");
            if(reqDto.getOrgInductionRecordList()==null || reqDto.getOrgInductionRecordList().isEmpty()){
                    return new ArrayList<>();
                }
        queryWrapper.in("user_id", reqDto.getOrgInductionRecordList());
            Map<String, Object> fieldInfoMap = null;
            fieldInfoMap = CommonFunctionHelper.objectToMapForLamBda(reqDto);
            List<FieldInfo> compareList = CommonFunctionHelper.getRangeField(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperCompare(queryWrapper, compareList, fieldInfoMap);
            List<FieldInfo> likeList = CommonFunctionHelper.getLikeFiled(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperLike(queryWrapper,likeList,fieldInfoMap);
            likeList.addAll(compareList);
            CommonFunctionHelper.buildQueryWrapperEq(queryWrapper, fieldInfoMap,likeList);
            List<FieldInfo> orderList = CommonFunctionHelper.getOrderList(InductionRecord.class);
            //CommonFunctionHelper.buildQueryWrapperOrder(queryWrapper, orderList);
            queryWrapper.orderByDesc("operate_time");
            return ((List<InductionRecord>) super.list(queryWrapper));
        } catch (Exception e) {
            e.printStackTrace();
            throw new BizException("-1",e,false);
        }
  }

    /**
   * 1-3-13批量查部门匹配就职记录[2976]
   * gen by moon at 10/23/2022, 2:26:16 PM
   */
 @Trace(operationName = "1-3-13批量查部门匹配就职记录")
 @Tags({@Tag(key = "参数",value = "arg[0]"),
 @Tag(key = "返回值",value = "returnedObj")})
  @Override
  @Transactional(rollbackFor=Exception.class)
  public  List<InductionRecord>  batchQueryDeptMatchInduction(BatchQueryDeptMatchInductionReq reqDto) {
     
        try {
            QueryWrapper<InductionRecord> queryWrapper = new QueryWrapper<>();
            reqDto.setIsValid("FALSE");
reqDto.setSpaceId(CommonFunctionHelper.getBaseInfoFromLocal().getSpecSpaceId());//CURRENT_SPACEID
reqDto.setAppId(CommonFunctionHelper.getBaseInfoFromLocal().getSpecAppId());//CURRENT_APPID
            if(reqDto.getOrgInductionRecordList()==null || reqDto.getOrgInductionRecordList().isEmpty()){
                    return new ArrayList<>();
                }
        queryWrapper.in("entity_id", reqDto.getOrgInductionRecordList());
            Map<String, Object> fieldInfoMap = null;
            fieldInfoMap = CommonFunctionHelper.objectToMapForLamBda(reqDto);
            List<FieldInfo> compareList = CommonFunctionHelper.getRangeField(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperCompare(queryWrapper, compareList, fieldInfoMap);
            List<FieldInfo> likeList = CommonFunctionHelper.getLikeFiled(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperLike(queryWrapper,likeList,fieldInfoMap);
            likeList.addAll(compareList);
            CommonFunctionHelper.buildQueryWrapperEq(queryWrapper, fieldInfoMap,likeList);
            List<FieldInfo> orderList = CommonFunctionHelper.getOrderList(InductionRecord.class);
            //CommonFunctionHelper.buildQueryWrapperOrder(queryWrapper, orderList);
            
            return ((List<InductionRecord>) super.list(queryWrapper));
        } catch (Exception e) {
            e.printStackTrace();
            throw new BizException("-1",e,false);
        }
  }

    /**
   * 1-3-13批量查询直属就职记录[3107]
   * gen by moon at 10/23/2022, 2:26:17 PM
   */
 @Trace(operationName = "1-3-13批量查询直属就职记录")
 @Tags({@Tag(key = "参数",value = "arg[0]"),
 @Tag(key = "返回值",value = "returnedObj")})
  @Override
  @Transactional(rollbackFor=Exception.class)
  public  List<InductionRecord>  batchQueryDirectInductionRecord(BatchQueryDirectInductionRecordReq reqDto) {
     
        try {
            QueryWrapper<InductionRecord> queryWrapper = new QueryWrapper<>();
            reqDto.setIsValid("FALSE");
reqDto.setSpaceId(CommonFunctionHelper.getBaseInfoFromLocal().getSpecSpaceId());//CURRENT_SPACEID
reqDto.setAppId(CommonFunctionHelper.getBaseInfoFromLocal().getSpecAppId());//CURRENT_APPID
            if(reqDto.getOrgInductionRecordList()==null || reqDto.getOrgInductionRecordList().isEmpty()){
                    return new ArrayList<>();
                }
        queryWrapper.in("position_type", reqDto.getOrgInductionRecordList());
            Map<String, Object> fieldInfoMap = null;
            fieldInfoMap = CommonFunctionHelper.objectToMapForLamBda(reqDto);
            List<FieldInfo> compareList = CommonFunctionHelper.getRangeField(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperCompare(queryWrapper, compareList, fieldInfoMap);
            List<FieldInfo> likeList = CommonFunctionHelper.getLikeFiled(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperLike(queryWrapper,likeList,fieldInfoMap);
            likeList.addAll(compareList);
            CommonFunctionHelper.buildQueryWrapperEq(queryWrapper, fieldInfoMap,likeList);
            List<FieldInfo> orderList = CommonFunctionHelper.getOrderList(InductionRecord.class);
            //CommonFunctionHelper.buildQueryWrapperOrder(queryWrapper, orderList);
            queryWrapper.orderByAsc("order_number");
queryWrapper.orderByDesc("operate_time");
            return ((List<InductionRecord>) super.list(queryWrapper));
        } catch (Exception e) {
            e.printStackTrace();
            throw new BizException("-1",e,false);
        }
  }
/**
   * M1-3-13查询单条就职记录详情[4278]
   * gen by moon at 3/31/2023, 3:24:04 AM
   */
 @Trace(operationName = "M1-3-13查询单条就职记录详情")
 @Tags({@Tag(key = "参数",value = "arg[0]"),
 @Tag(key = "返回值",value = "returnedObj")})
  @Override
  @Transactional(rollbackFor=Exception.class)
  public  InductionRecord  querySingleInductionRecordIdDetail(QuerySingleInductionRecordIdDetailReq reqDto) {
     
        try {
         reqDto.setSpaceId(CommonFunctionHelper.getBaseInfoFromLocal().getSpecSpaceId());//CURRENT_SPACEID
            QueryWrapper<InductionRecord> queryWrapper = new QueryWrapper<>();
            Map<String, Object> fieldInfoMap = null;
            fieldInfoMap = CommonFunctionHelper.objectToMapForLamBda(reqDto);
            CommonFunctionHelper.buildQueryWrapperEq(queryWrapper, fieldInfoMap, new ArrayList<>());
            queryWrapper.orderByDesc("create_time");
            List<InductionRecord> retList = super.list(queryWrapper);
            if(retList!=null && retList.size()>0){
                InductionRecord retData = retList.get(0);
                
                return retData;
            }
            return null;
      } catch (Exception e) {
          e.printStackTrace();
          throw new BizException("-1",e,false);
      }
  }
/**
   * M1批量查询就职记录测试[4866]
   * gen by moon at 10/23/2022, 2:26:18 PM
   */
 @Trace(operationName = "M1批量查询就职记录测试")
 @Tags({@Tag(key = "参数",value = "arg[0]"),
 @Tag(key = "返回值",value = "returnedObj")})
  @Override
  @Transactional(rollbackFor=Exception.class)
  public  List<InductionRecord>  batchQueryInductionRecordTestData(BatchQueryInductionRecordTestDataReq reqDto) {
     
        try {
            QueryWrapper<InductionRecord> queryWrapper = new QueryWrapper<>();
            
            if(reqDto.getInductionRecordTestDataList()==null || reqDto.getInductionRecordTestDataList().isEmpty()){
                    return new ArrayList<>();
                }
        queryWrapper.in("user_id", reqDto.getInductionRecordTestDataList());
            Map<String, Object> fieldInfoMap = null;
            fieldInfoMap = CommonFunctionHelper.objectToMapForLamBda(reqDto);
            List<FieldInfo> compareList = CommonFunctionHelper.getRangeField(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperCompare(queryWrapper, compareList, fieldInfoMap);
            List<FieldInfo> likeList = CommonFunctionHelper.getLikeFiled(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperLike(queryWrapper,likeList,fieldInfoMap);
            likeList.addAll(compareList);
            CommonFunctionHelper.buildQueryWrapperEq(queryWrapper, fieldInfoMap,likeList);
            List<FieldInfo> orderList = CommonFunctionHelper.getOrderList(InductionRecord.class);
            //CommonFunctionHelper.buildQueryWrapperOrder(queryWrapper, orderList);
            
            return ((List<InductionRecord>) super.list(queryWrapper));
        } catch (Exception e) {
            e.printStackTrace();
            throw new BizException("-1",e,false);
        }
  }
/**
   * M1批量删就职记录测试[4867]
   * gen by moon at 10/23/2022, 2:26:19 PM
   */
 @Trace(operationName = "M1批量删就职记录测试")
 @Tags({@Tag(key = "参数",value = "arg[0]"),
 @Tag(key = "返回值",value = "returnedObj")})
  @Override
  @Transactional(rollbackFor=Exception.class)
  public  boolean  batchDeleteInductionRecordTestData(List<String> reqDto) {
     
          if(reqDto==null || reqDto.size()==0){
            return false;
          }
          
          return super.removeByIds(reqDto);
  }
/**
   * 1-3-13批量查询平台就职记录(公共)[5025]
   * gen by moon at 10/27/2022, 5:05:39 AM
   */
 @Trace(operationName = "1-3-13批量查询平台就职记录(公共)")
 @Tags({@Tag(key = "参数",value = "arg[0]"),
 @Tag(key = "返回值",value = "returnedObj")})
  @Override
  @Transactional(rollbackFor=Exception.class)
  public  List<InductionRecord>  batchQueryPlatformInductionRecordCom(BatchQueryPlatformInductionRecordComReq reqDto) {

        try {
            QueryWrapper<InductionRecord> queryWrapper = new QueryWrapper<>();

            if(reqDto.getOrgInductionRecordList()==null || reqDto.getOrgInductionRecordList().isEmpty()){
                    return new ArrayList<>();
                }
        queryWrapper.in("induction_record_id", reqDto.getOrgInductionRecordList());
            Map<String, Object> fieldInfoMap = null;
            fieldInfoMap = CommonFunctionHelper.objectToMapForLamBda(reqDto);
            List<FieldInfo> compareList = CommonFunctionHelper.getRangeField(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperCompare(queryWrapper, compareList, fieldInfoMap);
            List<FieldInfo> likeList = CommonFunctionHelper.getLikeFiled(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperLike(queryWrapper,likeList,fieldInfoMap);
            likeList.addAll(compareList);
            CommonFunctionHelper.buildQueryWrapperEq(queryWrapper, fieldInfoMap,likeList);
            List<FieldInfo> orderList = CommonFunctionHelper.getOrderList(InductionRecord.class);
            //CommonFunctionHelper.buildQueryWrapperOrder(queryWrapper, orderList);

            return ((List<InductionRecord>) super.list(queryWrapper));
        } catch (Exception e) {
            e.printStackTrace();
            throw new BizException("-1",e,false);
        }
  }
/**
   * 1-3-14批量查询身份人员就职记录[5076]
   * gen by moon at 10/31/2022, 6:37:51 PM
   */
 @Trace(operationName = "1-3-14批量查询身份人员就职记录")
 @Tags({@Tag(key = "参数",value = "arg[0]"),
 @Tag(key = "返回值",value = "returnedObj")})
  @Override
  @Transactional(rollbackFor=Exception.class)
  public  List<InductionRecord>  batchQueryOriginalRoleMemberInductionRecord(BatchQueryOriginalRoleMemberInductionRecordReq reqDto) {

        try {
            QueryWrapper<InductionRecord> queryWrapper = new QueryWrapper<>();
            reqDto.setIsValid("FALSE");
reqDto.setSpaceId(CommonFunctionHelper.getBaseInfoFromLocal().getSpecSpaceId());//CURRENT_SPACEID
            if(reqDto.getOrgInductionRecordList()==null || reqDto.getOrgInductionRecordList().isEmpty()){
                    return new ArrayList<>();
                }
        queryWrapper.in("original_role_member_id", reqDto.getOrgInductionRecordList());
            Map<String, Object> fieldInfoMap = null;
            fieldInfoMap = CommonFunctionHelper.objectToMapForLamBda(reqDto);
            List<FieldInfo> compareList = CommonFunctionHelper.getRangeField(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperCompare(queryWrapper, compareList, fieldInfoMap);
            List<FieldInfo> likeList = CommonFunctionHelper.getLikeFiled(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperLike(queryWrapper,likeList,fieldInfoMap);
            likeList.addAll(compareList);
            CommonFunctionHelper.buildQueryWrapperEq(queryWrapper, fieldInfoMap,likeList);
            List<FieldInfo> orderList = CommonFunctionHelper.getOrderList(InductionRecord.class);
            //CommonFunctionHelper.buildQueryWrapperOrder(queryWrapper, orderList);
            queryWrapper.orderByDesc("position_order_number");
queryWrapper.orderByAsc("order_number");
queryWrapper.orderByDesc("operate_time");
            return ((List<InductionRecord>) super.list(queryWrapper));
        } catch (Exception e) {
            e.printStackTrace();
            throw new BizException("-1",e,false);
        }
  }
/**
   * 1-3-13批量查询就职记录by部门ID[5139]
   * gen by moon at 11/5/2022, 9:49:27 PM
   */
 @Trace(operationName = "1-3-13批量查询就职记录by部门ID")
 @Tags({@Tag(key = "参数",value = "arg[0]"),
 @Tag(key = "返回值",value = "returnedObj")})
  @Override
  @Transactional(rollbackFor=Exception.class)
  public  List<InductionRecord>  batchQueryInductionRecordByDeptId(BatchQueryInductionRecordByDeptIdReq reqDto) {

        try {
            QueryWrapper<InductionRecord> queryWrapper = new QueryWrapper<>();
            reqDto.setIsValid("FALSE");
reqDto.setSpaceId(CommonFunctionHelper.getBaseInfoFromLocal().getSpecSpaceId());//CURRENT_SPACEID
            if(reqDto.getInductionRecordByDeptIdList()==null || reqDto.getInductionRecordByDeptIdList().isEmpty()){
                    return new ArrayList<>();
                }
        queryWrapper.in("entity_id", reqDto.getInductionRecordByDeptIdList());
            Map<String, Object> fieldInfoMap = null;
            fieldInfoMap = CommonFunctionHelper.objectToMapForLamBda(reqDto);
            List<FieldInfo> compareList = CommonFunctionHelper.getRangeField(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperCompare(queryWrapper, compareList, fieldInfoMap);
            List<FieldInfo> likeList = CommonFunctionHelper.getLikeFiled(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperLike(queryWrapper,likeList,fieldInfoMap);
            likeList.addAll(compareList);
            CommonFunctionHelper.buildQueryWrapperEq(queryWrapper, fieldInfoMap,likeList);
            List<FieldInfo> orderList = CommonFunctionHelper.getOrderList(InductionRecord.class);
            //CommonFunctionHelper.buildQueryWrapperOrder(queryWrapper, orderList);

            return ((List<InductionRecord>) super.list(queryWrapper));
        } catch (Exception e) {
            e.printStackTrace();
            throw new BizException("-1",e,false);
        }
  }
/**
   * 1-3-13查询就职记录就职时间排序列表[7442]
   * gen by moon at 9/23/2023, 3:24:51 PM
   */
 @Trace(operationName = "1-3-13查询就职记录就职时间排序列表")
 @Tags({@Tag(key = "参数",value = "arg[0]"),
 @Tag(key = "返回值",value = "returnedObj")})
  @Override
  @Transactional(rollbackFor=Exception.class)
  public  List<InductionRecord>  queryInductionRecordStartTimeOrderList(QueryInductionRecordStartTimeOrderListReq reqDto) {

        try {
            QueryWrapper<InductionRecord> queryWrapper = new QueryWrapper<>();
            reqDto.setIsValid("FALSE");

            Map<String, Object> fieldInfoMap = null;
            fieldInfoMap = CommonFunctionHelper.objectToMapForLamBda(reqDto);
            List<FieldInfo> compareList = CommonFunctionHelper.getRangeField(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperCompare(queryWrapper, compareList, fieldInfoMap);
            List<FieldInfo> likeList = CommonFunctionHelper.getLikeFiled(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperLike(queryWrapper,likeList,fieldInfoMap);
            likeList.addAll(compareList);
            CommonFunctionHelper.buildQueryWrapperEq(queryWrapper, fieldInfoMap,likeList);
            List<FieldInfo> orderList = CommonFunctionHelper.getOrderList(InductionRecord.class);
            //CommonFunctionHelper.buildQueryWrapperOrder(queryWrapper, orderList);
            queryWrapper.orderByAsc("induction_start_time");
queryWrapper.orderByDesc("operate_time");
            return ((List<InductionRecord>) super.list(queryWrapper));
        } catch (Exception e) {
            e.printStackTrace();
            throw new BizException("-1",e,false);
        }
  }
/**
   * 1-3-13批量查询就职的部门[7892]
   * gen by moon at 11/11/2023, 1:46:30 AM
   */
 @Trace(operationName = "1-3-13批量查询就职的部门")
 @Tags({@Tag(key = "参数",value = "arg[0]"),
 @Tag(key = "返回值",value = "returnedObj")})
  @Override
  @Transactional(rollbackFor=Exception.class)
  public  List<InductionRecord>  batchQueryInductionDept(BatchQueryInductionDeptReq reqDto) {

        try {
            QueryWrapper<InductionRecord> queryWrapper = new QueryWrapper<>();
            reqDto.setIsValid("FALSE");
            if(reqDto.getOrgInductionRecordList()==null || reqDto.getOrgInductionRecordList().isEmpty()){
                    return new ArrayList<>();
                }
        queryWrapper.in("induction_record_id", reqDto.getOrgInductionRecordList());
            Map<String, Object> fieldInfoMap = null;
            fieldInfoMap = CommonFunctionHelper.objectToMapForLamBda(reqDto);
            List<FieldInfo> compareList = CommonFunctionHelper.getRangeField(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperCompare(queryWrapper, compareList, fieldInfoMap);
            List<FieldInfo> likeList = CommonFunctionHelper.getLikeFiled(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperLike(queryWrapper,likeList,fieldInfoMap);
            likeList.addAll(compareList);
            CommonFunctionHelper.buildQueryWrapperEq(queryWrapper, fieldInfoMap,likeList);
            List<FieldInfo> orderList = CommonFunctionHelper.getOrderList(InductionRecord.class);
            //CommonFunctionHelper.buildQueryWrapperOrder(queryWrapper, orderList);

            return ((List<InductionRecord>) super.list(queryWrapper));
        } catch (Exception e) {
            e.printStackTrace();
            throw new BizException("-1",e,false);
        }
  }
/**
   * 1-3-13批量查询就职记录快照[8098]
   * gen by moon at 12/6/2023, 5:01:52 PM
   */
 @Trace(operationName = "1-3-13批量查询就职记录快照")
 @Tags({@Tag(key = "参数",value = "arg[0]"),
 @Tag(key = "返回值",value = "returnedObj")})
  @Override
  @Transactional(rollbackFor=Exception.class)
  public  List<InductionRecord>  batchQueryInductionRecordSnap(BatchQueryInductionRecordSnapReq reqDto) {

        try {
            QueryWrapper<InductionRecord> queryWrapper = new QueryWrapper<>();

            if(reqDto.getOrgInductionRecordList()==null || reqDto.getOrgInductionRecordList().isEmpty()){
                    return new ArrayList<>();
                }
        queryWrapper.in("induction_record_id", reqDto.getOrgInductionRecordList());
            Map<String, Object> fieldInfoMap = null;
            fieldInfoMap = CommonFunctionHelper.objectToMapForLamBda(reqDto);
            List<FieldInfo> compareList = CommonFunctionHelper.getRangeField(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperCompare(queryWrapper, compareList, fieldInfoMap);
            List<FieldInfo> likeList = CommonFunctionHelper.getLikeFiled(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperLike(queryWrapper,likeList,fieldInfoMap);
            likeList.addAll(compareList);
            CommonFunctionHelper.buildQueryWrapperEq(queryWrapper, fieldInfoMap,likeList);
            List<FieldInfo> orderList = CommonFunctionHelper.getOrderList(InductionRecord.class);
            //CommonFunctionHelper.buildQueryWrapperOrder(queryWrapper, orderList);

            return ((List<InductionRecord>) super.list(queryWrapper));
        } catch (Exception e) {
            e.printStackTrace();
            throw new BizException("-1",e,false);
        }
  }
/**
   * 1-3-13执行批量部门查就职记录[8524]
   * gen by moon at 2/23/2024, 1:26:31 AM
   */
 @Trace(operationName = "1-3-13执行批量部门查就职记录")
 @Tags({@Tag(key = "参数",value = "arg[0]"),
 @Tag(key = "返回值",value = "returnedObj")})
  @Override
  @Transactional(rollbackFor=Exception.class)
  public  List<InductionRecord>  implementDeptInduction(ImplementDeptInductionReq reqDto) {

        try {
            QueryWrapper<InductionRecord> queryWrapper = new QueryWrapper<>();

            if(reqDto.getDeptMatchInductionList()==null || reqDto.getDeptMatchInductionList().isEmpty()){
                    return new ArrayList<>();
                }
        queryWrapper.in("entity_id", reqDto.getDeptMatchInductionList());
            Map<String, Object> fieldInfoMap = null;
            fieldInfoMap = CommonFunctionHelper.objectToMapForLamBda(reqDto);
            List<FieldInfo> compareList = CommonFunctionHelper.getRangeField(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperCompare(queryWrapper, compareList, fieldInfoMap);
            List<FieldInfo> likeList = CommonFunctionHelper.getLikeFiled(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperLike(queryWrapper,likeList,fieldInfoMap);
            likeList.addAll(compareList);
            CommonFunctionHelper.buildQueryWrapperEq(queryWrapper, fieldInfoMap,likeList);
            List<FieldInfo> orderList = CommonFunctionHelper.getOrderList(InductionRecord.class);
            //CommonFunctionHelper.buildQueryWrapperOrder(queryWrapper, orderList);

            return ((List<InductionRecord>) super.list(queryWrapper));
        } catch (Exception e) {
            e.printStackTrace();
            throw new BizException("-1",e,false);
        }
  }
/**
   * 1-3-13查询我下属就职记录列表[9032]
   * gen by moon at 4/1/2024, 1:38:13 AM
   */
 @Trace(operationName = "1-3-13查询我下属就职记录列表")
 @Tags({@Tag(key = "参数",value = "arg[0]"),
 @Tag(key = "返回值",value = "returnedObj")})
  @Override
  @Transactional(rollbackFor=Exception.class)
  public  List<InductionRecord>  querySubordinateInductionRecordList(QuerySubordinateInductionRecordListReq reqDto) {

        try {
            QueryWrapper<InductionRecord> queryWrapper = new QueryWrapper<>();


            Map<String, Object> fieldInfoMap = null;
            fieldInfoMap = CommonFunctionHelper.objectToMapForLamBda(reqDto);
            List<FieldInfo> compareList = CommonFunctionHelper.getRangeField(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperCompare(queryWrapper, compareList, fieldInfoMap);
            List<FieldInfo> likeList = CommonFunctionHelper.getLikeFiled(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperLike(queryWrapper,likeList,fieldInfoMap);
            likeList.addAll(compareList);
            CommonFunctionHelper.buildQueryWrapperEq(queryWrapper, fieldInfoMap,likeList);
            List<FieldInfo> orderList = CommonFunctionHelper.getOrderList(InductionRecord.class);
            //CommonFunctionHelper.buildQueryWrapperOrder(queryWrapper, orderList);

            return ((List<InductionRecord>) super.list(queryWrapper));
        } catch (Exception e) {
            e.printStackTrace();
            throw new BizException("-1",e,false);
        }
  }
/**
   * 1-3-13查询就职的部门列表[9363]
   * gen by moon at 4/10/2024, 10:45:40 AM
   */
 @Trace(operationName = "1-3-13查询就职的部门列表")
 @Tags({@Tag(key = "参数",value = "arg[0]"),
 @Tag(key = "返回值",value = "returnedObj")})
  @Override
  @Transactional(rollbackFor=Exception.class)
  public  List<InductionRecord>  queryInductionDeptList(QueryInductionDeptListReq reqDto) {

        try {
            QueryWrapper<InductionRecord> queryWrapper = new QueryWrapper<>();


            Map<String, Object> fieldInfoMap = null;
            fieldInfoMap = CommonFunctionHelper.objectToMapForLamBda(reqDto);
            List<FieldInfo> compareList = CommonFunctionHelper.getRangeField(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperCompare(queryWrapper, compareList, fieldInfoMap);
            List<FieldInfo> likeList = CommonFunctionHelper.getLikeFiled(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperLike(queryWrapper,likeList,fieldInfoMap);
            likeList.addAll(compareList);
            CommonFunctionHelper.buildQueryWrapperEq(queryWrapper, fieldInfoMap,likeList);
            List<FieldInfo> orderList = CommonFunctionHelper.getOrderList(InductionRecord.class);
            //CommonFunctionHelper.buildQueryWrapperOrder(queryWrapper, orderList);

            return ((List<InductionRecord>) super.list(queryWrapper));
        } catch (Exception e) {
            e.printStackTrace();
            throw new BizException("-1",e,false);
        }
  }
/**
   * 1-3-13批量查询我下属就职记录[10051]
   * gen by moon at 7/25/2024, 1:11:34 AM
   */
 @Trace(operationName = "1-3-13批量查询我下属就职记录")
 @Tags({@Tag(key = "参数",value = "arg[0]"),
 @Tag(key = "返回值",value = "returnedObj")})
  @Override
  @Transactional(rollbackFor=Exception.class)
  public  List<InductionRecord>  batchQuerySubordinateInductionRecord(BatchQuerySubordinateInductionRecordReq reqDto) {

        try {
            QueryWrapper<InductionRecord> queryWrapper = new QueryWrapper<>();

            if(reqDto.getOrgInductionRecordList()==null || reqDto.getOrgInductionRecordList().isEmpty()){
                    return new ArrayList<>();
                }
        queryWrapper.in("director_induction_record_id", reqDto.getOrgInductionRecordList());
            Map<String, Object> fieldInfoMap = null;
            fieldInfoMap = CommonFunctionHelper.objectToMapForLamBda(reqDto);
            List<FieldInfo> compareList = CommonFunctionHelper.getRangeField(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperCompare(queryWrapper, compareList, fieldInfoMap);
            List<FieldInfo> likeList = CommonFunctionHelper.getLikeFiled(InductionRecord.class);
            CommonFunctionHelper.buildQueryWrapperLike(queryWrapper,likeList,fieldInfoMap);
            likeList.addAll(compareList);
            CommonFunctionHelper.buildQueryWrapperEq(queryWrapper, fieldInfoMap,likeList);
            List<FieldInfo> orderList = CommonFunctionHelper.getOrderList(InductionRecord.class);
            //CommonFunctionHelper.buildQueryWrapperOrder(queryWrapper, orderList);

            return ((List<InductionRecord>) super.list(queryWrapper));
        } catch (Exception e) {
            e.printStackTrace();
            throw new BizException("-1",e,false);
        }
  }
}
